SET QUOTED_IDENTIFIER OFF
GO
SET ANSI_NULLS ON
GO
CREATE PROCEDURE [dbo].[spActualizarPlantasFuncionales]
@turno int,
@modalidad int,
@division varchar(7),
@curso varchar(3),
@funcion int,
@horas int,
@idPlaza int
AS
SET NOCOUNT ON
declare @idDivision int

Select @idDivision  = division from tb_Plazas where idplaza = @idPlaza

update tb_Divisiones
set curso = @curso, division = @division, turno = @turno, GrupoCarreras = @modalidad
where idDivision = @idDivision

update tb_Plazas 
set horas = @horas, funcion = @funcion
where idPlaza = @idPlaza
GO
